package com.micromall.repository.entity;

import com.fasterxml.jackson.annotation.JsonIgnore;

import java.math.BigDecimal;
import java.util.Date;

/**
 * Created by zhangzx on 16/3/26.
 * 订单商品
 */
public class OrderGoods extends IdEntity {

	// 所属订单
	@JsonIgnore
	private String          orderNo;
	// 购买数量
	private Integer         buyNumber;
	// 商品ID
	private Integer         goodsId;
	// 商品标题
	private String          title;
	// 商品图片
	private String          image;
	// 商品购买价格
	private BigDecimal      price;
	// 商品原始价格
	private BigDecimal      originPrice;
	@JsonIgnore
	// 创建时间
	private Date            createTime;
	// 临时字段
	// 运费模板id
	@JsonIgnore
	private Integer         freightId;
	// 总重量
	private BigDecimal      weight;
	@JsonIgnore
	private FreightTemplate freightTemplate;
	@JsonIgnore
	private FreightRules    freightRules;

	@JsonIgnore
	@Override
	public Integer getId() {
		return super.getId();
	}

	public String getOrderNo() {
		return orderNo;
	}

	public void setOrderNo(String orderNo) {
		this.orderNo = orderNo;
	}

	public Integer getBuyNumber() {
		return buyNumber;
	}

	public void setBuyNumber(Integer buyNumber) {
		this.buyNumber = buyNumber;
	}

	public Integer getGoodsId() {
		return goodsId;
	}

	public void setGoodsId(Integer goodsId) {
		this.goodsId = goodsId;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getImage() {
		return image;
	}

	public void setImage(String image) {
		this.image = image;
	}

	public BigDecimal getPrice() {
		return price;
	}

	public void setPrice(BigDecimal price) {
		this.price = price;
	}

	public BigDecimal getOriginPrice() {
		return originPrice;
	}

	public void setOriginPrice(BigDecimal originPrice) {
		this.originPrice = originPrice;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Integer getFreightId() {
		return freightId;
	}

	public void setFreightId(Integer freightId) {
		this.freightId = freightId;
	}

	public BigDecimal getWeight() {
		return weight;
	}

	public void setWeight(BigDecimal weight) {
		this.weight = weight;
	}

	public FreightTemplate getFreightTemplate() {
		return freightTemplate;
	}

	public void setFreightTemplate(FreightTemplate freightTemplate) {
		this.freightTemplate = freightTemplate;
	}

	public FreightRules getFreightRules() {
		return freightRules;
	}

	public void setFreightRules(FreightRules freightRules) {
		this.freightRules = freightRules;
	}
}
